<?php
$hour=date("H");
if($hour>1 && $hour<9){
    echo "it is sleep time!\r\n";
    exit;
}
include("setup.php");

$group_url="http://www.douban.com/group/";
$str=_file_get_contents($group_url,1,array(),COOKIEJAR);
file_put_contents("check.html",$str);
if(strpos($str,"http://www.douban.com/group/explore")!==false){
    c("Need login!");
    exit;
}
c("Start get topic data!");

file_put_contents("get_topic.html",$str);